const myInstanceOf = (target, origin) => {
  // 进行循环，当寻找target的原型链上找到与origin原型相同则返回true（期间一直target = target.__proto__为原型链赋值），没有返回false
  while (target) {
    if (target.__proto__ === origin.prototype) {
      return true
    }
    target = target.__proto__
  }
  return false
}

const a = [1,3,4]

console.log(myInstanceOf(a,a),a.__proto__,1,a.prototype);